package ExamLab.Test1;

public class ExamLabView {
	public static void main(String args[]) {
		
		String a = "a";
		Object b = new StringBuilder("b");
		Object c = new StringBuffer("c");
		Object d = a + b;
		Object e = c + a;
		Boolean b1 = new Boolean(d instanceof String);			// true
		Boolean b2 = new Boolean(d instanceof StringBuilder);	// false
		Boolean b3 = new Boolean(e instanceof String);			// true
		Boolean b4 = new Boolean(e instanceof StringBuffer);	// false
		Boolean b5 = new Boolean(b instanceof StringBuilder);	// true
		Boolean b6 = new Boolean(c instanceof StringBuffer);	// true
		Boolean b7 = new Boolean(c instanceof StringBuilder);	// false
		
		System.out.print(b1 + ", " + b2 + ", " + b3 + ", " + b4 + ", " + b5 + ", " + b6 + ", " + b7);
	}
}